package com.example.cloud.model.basic;

import com.example.cloud.model.common.CommonModel;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

/**
 * Created by wangtao on 2018/6/5.
 * 品类管理
 */
@Entity(name = "basic_category")
@Data
@EqualsAndHashCode(callSuper = false)
public class Category extends CommonModel {
    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    private Long id;
    // 名称
    @Column(name = "name")
    private String name;
    // 商品大类ID
    @Column(name = "parent_id")
    private Long parentId;
    // 商品大类名称
    @Column(name = "parent_name")
    private String parentName;
    // 账户编号
    @Column(name = "account_id")
    private Long accountId;
    // 用户编号
    @Column(name = "user_id")
    private Long userId;
    // 组织机构编号
    @Column(name = "organ_id")
    private Long organId;
    // 组织机构名称
    @Column(name = "organ_name")
    private String organName;
}
